package com.yunhe.iservice.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.yunhe.bean.GlobalUser;
import com.yunhe.dao.GlobalUserDao;
import com.yunhe.iservice.LoginIService;

@Service
public class LoginIServiceImpl implements LoginIService{

	@Autowired
	private GlobalUserDao globalUserDao;
	//private SqlSessionFactory sqlSessionFactory;

	//public void setSqlSessionFactory(SqlSessionFactory sqlSessionFactory) {
	//	this.sqlSessionFactory = sqlSessionFactory;
	//}

	@Override
	public GlobalUser login(GlobalUser user) {
		//SqlSession sqlSession=sqlSessionFactory.openSession();
		//GlobalUserDao globalUserDao=(GlobalUserDao) sqlSession.getMapper(GlobalUserDao.class);
		//GlobalUser gu=globalUserDao.login(user);
		//sqlSession.close()
		return globalUserDao.login(user);
	}



}
